package com.oceansoft.core.jxkh.service.impl;

import com.oceansoft.core.common.util.Pagination;
import com.oceansoft.core.jxkh.dao.IKhyDao;
import com.oceansoft.core.jxkh.domain.Khy;
import com.oceansoft.core.jxkh.service.IKhyService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.List;

/**
 * Created by OS on 2017/12/11.
 */

@Service
public class KhyServiceImpl implements IKhyService {

    @Resource
    private IKhyDao khyDao;

    @Override
    public Pagination findAllKhy(HashMap<String, String> map) {
        return khyDao.findAllKhy(map);
    }

    @Override
    public List<Khy> findAllKhy() throws Exception {
        return khyDao.findAllKhy();
    }

    @Override
    public void editKhyInfo(Khy khy) {
        khyDao.editKhyInfo(khy);
    }

    @Override
    public Khy findKhyInfoByDbid(int dbid) {
        return khyDao.findKhyInfoByDbid(dbid);
    }

    @Override
    public void deleteKhyInfoByDbid(int dbid) {
        khyDao.deleteKhyInfoByDbid(dbid);
    }

    @Override
    public void addKhyInfo(Khy khy) {
        khyDao.addKhyInfo(khy);
    }

    @Override
    public void batchDeleteKhyInfo(int[] dbids) {
        khyDao.batchDeleteKhyInfo(dbids);
    }

    @Override
    public List findAllKhyName() {
        return khyDao.findAllKhyName();
    }
}
